package org.ldx.lotterysystem.service;

import org.ldx.lotterysystem.controller.param.UserLoginParam;
import org.ldx.lotterysystem.controller.param.UserPasswordLoginParam;
import org.ldx.lotterysystem.controller.param.UserRegisterParam;
import org.ldx.lotterysystem.service.dto.UserDto;
import org.ldx.lotterysystem.service.dto.UserLoginDto;
import org.ldx.lotterysystem.service.dto.UserRegisterDTO;
import org.ldx.lotterysystem.service.enums.UserIdentityEnum;

import java.util.List;

public interface UserService {
    /**
     * 注册
     */
    UserRegisterDTO register(UserRegisterParam param);

    /**
     *一个方法解决两种登录方式问题
     * @param param 两种参数对象的父类
     *              不仅实现了高聚合低耦合
     *              而且巧妙的抽取元素封装成对象，实现了多态。
     * @return
     */
    UserLoginDto login(UserLoginParam param);

    List<UserDto> findUserInfoList(UserIdentityEnum userIdentityEnum);
}
